package cn.itcast.bos.service.Impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import cn.itcast.bos.dao.base.IRegionDao;
import cn.itcast.bos.domain.Region;
import cn.itcast.bos.domain.pagebean.PageBean;
import cn.itcast.bos.service.IRegionService;

@Service
@Transactional
public class RegionServiceImpl implements IRegionService{
	@Resource
	private IRegionDao regionDao;

	@Override
	public void uploadXLS(List<Region> list) {
		for (Region region : list) {
			regionDao.saveOrUpload(region);
		}
	}

	@Override
	public void pageQueryList(PageBean pageBean) { 
		regionDao.pageQueryList(pageBean);
	}

	@Override
	public List<Region> findAll() {
		return regionDao.findAll();
	}

}
